This application is based upon and claims priority from prior French Patent Application No. 98-00450, filed Jan. 16, 1998, the entire disclosure of which is herein incorporated by reference.
1. Field of the Invention
The present invention relates to digital transmission, and more specifically to an efficient method for communicating between master and slave units by using a protocol having improved acknowledgment during message reception.
2. Description of Related Art
Digital transmissions can be made by means of different media. The transmission channels may indeed be either wire links, optical fibers, or a volume of air between two antennas. FIG. 1 shows an example of communication using RF links. As shown, a master unit 1 uses a transceiver antenna 11 to exchange messages with a slave unit 2 having a transceiver antenna 22. The transmission channel is formed by the volume of air between the two antennas 11 and 22. Each of the master unit and the slave unit can transmit messages to the other unit and receive messages from the other unit. The master unit is distinguished from the slave unit in that the master unit takes the initiative in the communication. For example, the master unit can be the central processing unit of a computer, and the slave unit can be one of its peripherals such as a printer that is remote-controlled by means of any transmission channel.
There are conventional methods of communication that consist of transmitting messages that include a useful information word and one or more service bits. The transmission is carried out serially according to a specified communications protocol. A protocol of this kind specifies the format and the syntax of the messages that are transmitted by the master unit to the slave unit or vice versa. The transmission is done synchronously, and is sequenced at a specified rate with the units including conventional circuitry to lock in to the rate the same clock or two synchronous or dia-synchronous clocks.
FIG. 2 shows an example of a conventional elementary message format. The elementary message begins with a starting bit START whose function is to synchronize the clock of the addressed unit with the received message. Then, the message includes an encoded useful information word INFO (e.g., encoded in eight bits or one byte). This word may be an instruction word whose value indicates the nature of a command to be carried out by the addressed unit. For example a read or write command. Alternatively, it could be an address word whose value indicates the address (or a part of the address) of a memory location of the addressed unit at which a data element is to be read or written. Additionally, the word can be a data word whose value indicates the value of a data element processed by the addressed unit.
The elementary message also includes a check bit CHECK such as a parity check bit. The value of the parity check bit CHECK is fixed at the logic value 1 or 0, and is determined in such a way that the sum of the values of the bits of the useful information INFO gives an even value or an odd value depending on the chosen type of parity. The role of the parity check bit CHECK is to enable the addressed unit to detect any transmission errors. In such a case, the addressed unit can request a re-transmission of the message.
The conventional message ends with an end-of-transmission bit STOP that is used solely to indicate the end of the message. Following the end-of-transmission bit STOP, each protocol generally provides for a number of elementary temporal units during which the sending unit no longer sends any bit on the transmission channel. Thus, the transmission channel is left free so that the addressed unit can send a bit ACK to acknowledge the communication. The logic value of the acknowledgment bit indicates whether the message has been accurately received. The circuitry conventionally used to determine whether the message has been accurately received is the check performed by means of the parity check bit CHECK. In FIG. 2, four such elementary temporal units follow the bit STOP, with one of these temporal units being occupied by the reception acknowledgment bit ACK.
There presently exists a very large quantity of different communication protocols for electronic systems. Each protocol is suited to the specific constraints of a specific application (such constraints including the size of the words to be transmitted, coherence checks, the need to securitize communications against passive or active intervention by ill-intentioned individuals, constraints related to acknowledgment mode, and maximum duration of transmission in relation to the bit rate). Within one system, the master unit and the slave unit obviously conform the same communications protocol so that they can intelligibly communicate with each other intelligibly.
In general, the information on the communications protocols developed by electronics systems manufacturers is widely disseminated in order to enable other manufacturers to incorporate these systems into more complex assemblies or develop new industrial and/or commercial applications. Thus, with respect to the size of the communications in which such protocols are used, the integrity of the information transmitted and the efficiency of the transmission has to be the optimum. In other words, it is necessary for the transmission to be affected by a minimum of errors. Furthermore, there are applications in which the integrity of the information exchanged and the efficiency of communication are major constraints in the specifications. Conventionally, quality control of the transmission of the binary signals lies essentially in the analysis and interpretation of the value of the parity check bit CHECK described above.
FIGS. 3A and 3B show two possible cases to illustrate the determining of the parity bit CHECK. In these examples, the message format of FIG. 2 is used. In the figures, no special attention has been paid to the values of the starting bit START and end-of-transmission bit STOP. All that has been taken into account is the values of the bits of the useful information word INFO, the parity check bit CHECK, and the acknowledgment bit ACK. FIG. 3A shows the case of a useful information word INFO1 whose transmission has not been erroneous. The logic value 1 is illustratively given to the first seven bits B1, B2, B3, B4, B5, B6, and B7 of the useful information word INFO1, and the last bit B8 of the useful information word INFO1 is set at the logic value 0.
If an xe2x80x9cevenxe2x80x9d type of parity is used, the parity check bit CHECK will then take the logic value 1. That is, the sum of the values of the eight bits of the useful information word INFO1 added to the value of the parity bit CHECK gives the number 8 in conformity with even parity. In the case of FIG. 3A, the transmission of the useful information word INFO1 is not affected by errors so the useful information word INFO2 that results from the transmission of the useful information word INFO1 consequently has the same binary values for each of the bits. In general, a circuit formed by elementary logic gates is used to ascertain that the result of the transmission of the useful word is in conformity with the expected result with respect to the value of the received parity check bit and the type of parity adopted. Thus, as shown in FIG. 3A, the acknowledgment bit has the value that indicates accurate reception. (In FIGS. 3A and 3B, accurate acknowledgment illustratively corresponds to a value 1 of the acknowledgment bit ACK.)
FIG. 3B shows a case with the same useful information word INFO1, but for a transmission error. A useful information word INFO3 is received in the reception unit following the transmission of the useful information word INFO1 . In FIG. 3B, the eighth bit B8 of the received useful information word INFO3 is different from the eighth bit of the transmitted useful information word INFO1. Thus, the transmission has been erroneous and the useful information word INFO3 no longer matches with the parity check bit CHECK. The same result would occur if three, five, or seven of the eight bits constituting the received useful information word INFO3 had been different from the bits of the transmitted useful information word INFO1. Indeed, in all these cases, the sum of the eight bits of the useful information word INFO3 added to the value of the parity check bit CHECK gives an odd number while the type of parity is even parity. Consequently, in FIG. 3B, the acknowledgment bit ACK has the value 0.
The transmission of a message includes three or four phases of reception and transmission depending on whether the operation is in read mode or in write mode. The order of these phases is important. For example, for a write operation, a sequence for the transmission of a message can be subdivided for example into four phases of transmission that correspond, for each phase, to the transmission of an elementary message containing a useful information word of a different type. In write mode, the first transmission phase is the transmission of a code pertaining to an instruction to be performed, and the second transmission phase is the transmission of the least significant bits of the memory address at which it is sought to write a data element. The third transmission phase is a transmission of the most significant bits of the same memory address, and the fourth transmission phase is a transmission of the bits constituting the data element to be written at the memory address.
For a read operation, a sequence for the transmission of a message can be subdivided into three phases of transmission that correspond, for each phase, to the transmission of an elementary message containing a useful information word of a different type. The three transmission phases are the three first phases described above for a write operation. Conventionally, when an error is detected by a test relating to the parity check bit, the transmission sequence is resumed at the first transmission phase of the message, regardless of the current transmission phase. Thus, even if earlier phases of the transmission have been accurately acknowledged, such transmission phases must be undertaken again as part of the entire transmission process. This lowers the efficiency of the transmission.
In view of these drawbacks, it is an object of the present invention to remove the above-mentioned drawbacks and to provide an acknowledgment of reception that enables a re-transmission of the current phase of the transmission sequence. A counter is provided that can be used to count the number of re-transmissions of one and the same transmission phase. At the end of a predetermined number of re-transmissions of the same phase of the transmission sequence, the counter is reset and the transmission sequence is again performed starting from the first transmission phase.
One embodiment of the present invention provides a method for communicating between a transmitting unit and a receiving unit. According to the method, a messages formed by elementary messages is transmitted from the transmitting unit to the receiving unit, and at least one reception bit is transmitted from the receiving unit to the transmitting unit. The reception bit (or bits) allows the transmitting unit to determine the elementary message that is to be transmitted next. Thus, an improvement is introduced into the protocol to determine the following transmission phase in a transmission sequence. In a preferred method, at least two reception bits are transmitted from the receiving unit and the values of the reception bits indicate the elementary message that is to be transmitted next by the transmitting unit.
Another embodiment of the present invention provides a receiving device for receiving messages from a transmitting device. The receiving device includes an interface for receiving a transmitted message from the transmitting device, means for analyzing a received elementary message to determine if it was properly received, and a transmitter for transmitting at least one reception bit to the transmitting device. The reception bit (or bits) indicates the elementary message that is to be transmitted next by the transmitting unit. In one preferred embodiment, the transmitter transmits at least two reception bits whose values indicate the elementary message that is to be transmitted next by the transmitting unit.
Other objects, features, and advantages of the present invention will become apparent from the following detailed description. It should be understood, however, that the detailed description and specific examples, while indicating preferred embodiments of the present invention, are given by way of illustration only and various modifications may naturally be performed without deviating from the present invention.